package com.chinasofti.collection;

public class Demo04 {
    public static void main(String[] args) {
        int sum = getJc(5);
        System.out.println("sum = " + sum);
    }

    public static int  getJc(int i){

        if(i == 1){
            return 1;
        }else{
            return i * getJc(i - 1);
        }
    }
}
